package com.ssy.lingxi.system.service;

import com.ssy.lingxi.common.response.PageData;
import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.system.dto.request.*;
import com.ssy.lingxi.system.dto.response.MiddlegroundUserDetailsResponse;
import com.ssy.lingxi.system.dto.response.MiddlegroundUserLoginResponse;
import com.ssy.lingxi.system.dto.response.MiddlegroundUserResponse;
import com.ssy.lingxi.system.entity.LoginResponse;
import org.springframework.web.bind.annotation.RequestBody;

import javax.servlet.http.HttpServletRequest;

public interface MiddlegroundUserService {

    /**
    * 查询中台用户列表
    * @author wrc
    * @date 2020/5/20
    */
    Wrapper<PageData<MiddlegroundUserResponse>> middlegroundUserList(MiddlegroundUserRequest request);

    /**
    * 用户登录
    * @author wrc
    * @date 2020/5/21
    */
    Wrapper<LoginResponse> middlegroundUserLogin(HttpServletRequest request, MiddlegroundUserLoginRequest dtoRequest);

    /**
    * 根据用户token获取用户信息
    * @author wrc
    * @date 2020/5/21
    */
    Wrapper<MiddlegroundUserLoginResponse> middlegroundUserDetails(HttpServletRequest dtoRequest);


    /**
     *添加用户
     * @author wrc
     * @date 2020/5/22
     */
    Wrapper middlegroundUserAdd(HttpServletRequest httpServletRequest, MiddlegroundUserAddRequest request);


    /**
    * 修改用户信息
    * @author wrc
    * @date 2020/7/23
    */
    Wrapper middlegroundUserUpdate(@RequestBody MiddlegroundUserUpdateRequest request);


    /**
    * 修改用户状态
    * @author wrc
    * @date 2020/7/23
    */
    Wrapper middlegroundUserUpdateState(@RequestBody MiddlegroundUserUpdateStateRequest request);


    /**
    * 获取用户信息详情
    * @author wrc
    * @date 2020/7/23
    */
    Wrapper<MiddlegroundUserDetailsResponse> middlegroundUserDetailsById(MiddlegroundUserDetailsRequest request);


    /**
    * 删除用户信息
    * @author wrc
    * @date 2020/7/23
    */
    Wrapper middlegroundUserDeleteById(MiddlegroundUserDetailsRequest request, HttpServletRequest httpServletRequest);
}
